#include "stdafx.h"
#include "WorkholidayCalendar.h"


QWorkHolidayCalendar::QWorkHolidayCalendar(QWidget *parent)
	: QCalendarWidget(parent)
{
	
}

QWorkHolidayCalendar::~QWorkHolidayCalendar()
{

}
void QWorkHolidayCalendar::mousePressEvent(QMouseEvent *e)
{
	if (e->button() == Qt::LeftButton)
	{
		qMsgBoxInfo(tr("LeftButton click"));
	}
	else if (e->button() == Qt::RightButton)
	{
		qMsgBoxInfo(tr("RightButton click"));
	}
}
void QWorkHolidayCalendar::mouseDoubleClickEvent(QMouseEvent *e)
{
	/*if (e->button() == Qt::LeftButton)
		qMsgBoxInfo(tr("LeftButton doubleClick"));*/
	if (e->type() == QMouseEvent::MouseButtonDblClick)
	{
		//connect(ui->calendarWidget, SIGNAL(clicked(QDate)), this, SLOT(double_cal()));
		qMsgBoxInfo(tr("LeftButton doubleClick"));
	}
}
